package main

import (
	"fmt"
	"reflect"
)

func main() {
	arr := []int{1, 2, 3, 4}
	dup := arr
	arr[0] = -1
	print(dup)
	print(arr)
	fmt.Println(reflect.TypeOf(arr))
}

// 打印数组
func print(arr []int) {
	for _, value := range arr {
		fmt.Printf("%d\t", value)
	}
	fmt.Println()
}
